package com.yang.dreammanage.pojo;

import java.io.Serial;
import java.io.Serializable;

/**
 * 统一结果集
 * @param <T>
 */
public class Result<T> implements Serializable {

    @Serial
    private static final long serialVersionUID = 7181670507190678303L;
    private Integer code;
    private String message;
    private T data;

    public Result() {
    }

    public Result(Integer code, String message, T data) {
        this.code = code;
        this.message = message;
        this.data = data;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public T getData() {
        return data;
    }

    public void setData(T data) {
        this.data = data;
    }
}
